function qumhzh
m=50;n=40;
x=linspace(-8,8,m);
y=linspace(-8,8,n);
[x,y]=meshgrid(x,y);
z=f(x,y);
p=mesh(x,y,z);
set(p,'facecolor','r','edgecolor','k')
hold on
z1=fp(x,y);
p1=mesh(x,y,z1);
set(p1,'facecolor','g','edgecolor','b')
hold off
print -djpeg90 ͼƬ2
end
function z=f(x,y)
r=sqrt(x.^2+y.^2);
z=sin(r)./r;
end
function z=fp(x,y)
z=zeros(size(x))+0.5;
end